/**
 * Copyright 2009-2015 the original author or authors.
 * <p>
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * <p>
 * http://www.apache.org/licenses/LICENSE-2.0
 * <p>
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.apache.ibatis.logging;

/**
 * Log 日志接口
 *
 * @author Clinton Begin
 */
public interface Log {

  /**
   * 是否启用 debug
   *
   * @return true or false.
   */
  boolean isDebugEnabled();

  /**
   * 是否启用 trace
   *
   * @return true or false.
   */
  boolean isTraceEnabled();

  /**
   * error 级别日志输出
   *
   * @param s 错误信息
   * @param e 异常信息
   */
  void error(String s, Throwable e);

  /**
   * error 级别日志输出
   *
   * @param s 错误信息
   */
  void error(String s);

  /**
   * debug 级别日志输出
   *
   * @param s 错误信息
   */
  void debug(String s);

  /**
   * trace 级别日志输出
   *
   * @param s 错误信息
   */
  void trace(String s);

  /**
   * warn 级别日志输出
   *
   * @param s 错误信息
   */
  void warn(String s);

}
